package com.geek.factory.entity;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.time.LocalDate;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 入库单明细表，产品/原料二选一
 * </p>
 *
 * @author author
 * @since 2025-06-27
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("stock_in_detail")
@ApiModel(value="StockInDetail对象", description="入库单明细表，产品/原料二选一")
public class StockInDetail implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "明细ID")
    @TableId(value = "detail_id", type = IdType.AUTO)
    private Integer detailId;

    @ApiModelProperty(value = "入库单ID（关联主表）")
    private Integer stockInId;

    @ApiModelProperty(value = "产品ID（可选，产品入库时填写）")
    private Integer productId;

    @ApiModelProperty(value = "原料ID（可选，原料入库时填写）")
    private Integer materialId;

    @ApiModelProperty(value = "货柜ID（关联shelves表）")
    private Integer shelfId;

    @ApiModelProperty(value = "入库数量")
    private BigDecimal quantity;

    @ApiModelProperty(value = "单位")
    private String unit;

    @ApiModelProperty(value = "批次号")
    private String batchNo;

    @ApiModelProperty(value = "生产日期")
    private LocalDate productionDate;

    @ApiModelProperty(value = "有效期/失效日期")
    private LocalDate expireDate;

    @ApiModelProperty(value = "备注")
    private String remark;


}
